import request from '@/utils/request'
const baseUrl = '/cz-rentbox/api/v1' 
//工作台
// 货代****************************************
// 货代我的待办 - 租箱
export const hdRentTodo = () => {
  return request({
    url: baseUrl+"/homePageAgent/rentTodo",
    method: 'GET',
  })
}
//货代我的代办 回调
export const hdCallbackTodo = (data:any) => {
  return request({
    url: baseUrl +"/homePageAgent/callbackTodo",
    method: 'GET',
    data:data
  })
}
// 货代我的代办 购箱
export const saleBoxTodo1 = () => {
  return request({
    url: baseUrl +"/homePageAgent/saleBoxTodo",
    method: 'GET',
  })
}
//货代租箱柱状图
export const hdRentOrderQty = (data: any) => {
  return request({
    url: baseUrl+"/homePageAgent/rentOrderQty",
    method: 'GET',
  })
}
// 货代回调箱柱状图/homePageAgent/callbackOrderQty
export const hdCallbackOrderQty = () => {
  return request({
    url: baseUrl +"/homePageAgent/callbackOrderQty",
    method: 'GET',
  })
}
// 货代购箱柱状图/homePageAgent/saleOrderQty
export const hdSaleOrderQty = () => {
  return request({
    url: baseUrl +"/homePageAgent/saleOrderQty",
    method: 'GET',
  })
}
//货代折线图
export const hdRentOrderDateAnalysis = (data:any) => {
  return request({
    url: baseUrl +"/homePageAgent/rentOrderDateAnalysis",
    method: 'POST',
    data: data
  })
}
// 货代购箱折线图/homePageAgent/saleOrderDateAnalysis
export const hdSaleOrderDateAnalysis = (data:any) => {
  return request({
    url: baseUrl +"/homePageAgent/saleOrderDateAnalysis",
    method: 'POST',
    data: data
  })
}


// 货代回调折线图/homePageAgent/callbackOrderDateAnalysis
export const hdCallbackOrderDateAnalysis = (data:any) => {
  return request({
    url: baseUrl +"/homePageAgent/callbackOrderDateAnalysis",
    method: 'POST',
    data: data
  })
}

// 集装箱公司（租箱）****************************************
// 集装箱公司我的待办
export const rentTodo = () =>{
  return request({
    url: baseUrl+"/homePageBoxEast/rentTodo",
    method: 'GET',
  })
}
//集装箱公司回调代办
export const callbackTodo = (data:any) =>{
  return request({
    url: baseUrl +"/homePageBoxEast/callbackTodo",
    method: 'GET',
    data:data
  })
}
// 集装箱公司代办柱状图
// http://47.122.3.254:9999/cz-rentbox/api/v1/homePageBoxEast/rentOrderQty
export const rentOrderQty = () =>{
  return request({
    url: baseUrl+"/homePageBoxEast/rentOrderQty",
    method: 'GET',
  })
}
// 集装箱公司回调柱状图
// homePageBoxEast / callbackOrderQty
export const callbackOrderQty = () =>{
  return request({
    url: baseUrl +"/homePageBoxEast/callbackOrderQty",
    method: 'GET',
  })
}

// 下单折线图


// {
//   "dataType":3,
//   "beginDataTime": 20240808,
//   "endDataTime": 20240820
// }

// # 参数说明：
// # 输入model
//   # dataType:数据类型(3-日 5-月份 10-季度 15-年份)
//   # 日期格式时间区间(格式:日:20240808 月份:202408 季度:20241 20242 20243 20244 年份:2024)
//   # beginDataTime: 开始时间
//   # endDataTime: 结束时间

export const rentOrderLine = (data:any) =>{
  return request({
    url: baseUrl+"/homePageBoxEast/rentOrderDateAnalysis",
    method: 'POST',
    data:data
  })
}

//集装箱公司回调折线图
export const xdCallbackOrderLine = (data:any) =>{
  return request({
    url: baseUrl +"/homePageBoxEast/callbackOrderDateAnalysis",
    method: 'POST',
    data:data
  })
}
//

// ****************************************
// 卖箱我的待办

// 卖箱（箱贸）
// 代办统计
export const saleBoxTodo = () =>{
  return request({
    url: baseUrl +"/homePageSale/saleBoxTodo",
    method: 'GET',
  })
}
//卖相柱状图/homePageSale/saleOrderQty
export const mxSaleOrderQty = () =>{
  return request({
    url: baseUrl +"/homePageSale/saleOrderQty",
    method: 'GET',
  })
}

//卖箱折线图 /homePageSale/saleOrderDateAnalysis
export const mxSaleOrderLine = (data:any) =>{
  return request({
    url: baseUrl +"/homePageSale/saleOrderDateAnalysis",
    method: 'POST',
    data:data
  })
}


